"""两个列表拼接到一起
def join_list(a1,a2):
    result=[]
    result.extend(a1)
    result.extend(a2)
    print(result)

join_list([123,123,12,2,234,5,],[3,2,2,24,44])
"""
"""
def get_name(data):
    sum_counter = 0
    for i in data:
        if i =='A':
            sum_counter +=1

    return sum_counter
def write_f(line):
    if len(line)==0:
        return False
    with open('a1.txt',mode='w',encoding='utf-8') as f:
        f.write(line)

    return True

content = input("请输入：")
counter = get_name(content)
write_data = "zky"*counter
status = write_f(write_data)
if status:
    print("写入成功")
else:
    print("写入失败")
get_name()
"""

"""计算列表里有多少数字
def get_many_char(a1):
    count = 0
    for i in a1:
        if type(i) == int:
            count += 1

    return count


num = get_many_char(['asd', '3', 3, 5, 6, 1, 56, 0])
msg = '列表中有%s字' % (num,)
print(msg)
"""

"""计算偶数位置，并追加新列表
def even_list(v):
    even_number_list = []
    for i in range(0,len(v)):
        if i % 2 == 0:
           even_number_list.append(v[i])
    print(even_number_list)
    return  even_number_list
list = even_list([123,'eqw','sdas','zxc',4234,3,324,5,2345,25,]) 
"""

"""
def a_f(file):
    with open('a.log', mode='r', encoding='utf-8') as file1:
        content = file1.read()
        v1 = content.split("\n")
    return v1
"""

# 99称霸表print('%s'.join("".join('%s * %s =%2s ' % (j, i, i * j) for j in range(1, i + 1)) for i in range(1, 10)))
"""输粗人物属性
def func(name, gender, age, edu):
    data_list = [name, gender, age, edu]
    return "*".join(data_list)


n1 = input(">")
n2 = input('>')
n3 = input('>')
n4 = input('>')
result = func(n1, n2, n3, n4)
print(result)
"""

"""检查密码用户名
def user_name(name):
    with open('data.txt', mode='r', encoding='utf-8') as file1:
        content = file1.read()
        name = input("请输入用户名:")
        pwd = input("输入密码:")
        success = False
        if name in content and pwd in content:
            success = True
    print(success)
    return success


val = user_name("user")
"""
"""检查用户
def user_name(name):
    with open('data.txt', mode='r', encoding='utf-8') as file1:
        content = file1.read()
        data_list = content.split('\n')
        for i in data_list:
            v = i.split('|')
            if v[1] == name:
                return True
v1 = user_name('alex')
if v1:
    print('存在')
else:
    print('不存在')
"""